/*
 * Exploder
 * 
 * Tero Pyylampi (218437), Jussi Tuurinkoski (211594)
 *
 * An engine for updating all the physic objects in the game
 */

#ifndef GAMEINTERFACEENGINE_H
#define GAMEINTERFACEENGINE_H

#include "../objects/GameAbstractEngine.h"

class GameInterfaceObject;
class GameInterfaceEditorContainer;
class GameInterfaceGameContainer;
class MainEngine;
class EditorScene;
class GameScene;

class GameInterfaceEngine : public GameAbstractEngine {
public:
	// default constructor
	GameInterfaceEngine();
	// default destructor
	virtual ~GameInterfaceEngine();

	// update engine state
	virtual void update( cocos2d::ccTime dt );

	// create interface for game mode
	void createGameModeInterface( cocos2d::CCLayer *layer, MainEngine *mainEngine, GameScene *gameScene );

	// create interface for editor mode
	void createEditorModeInterface( cocos2d::CCLayer *layer, MainEngine *mainEngine, EditorScene *editorScene );

	// get objects
	std::vector< GameInterfaceObject* > *getInterfaceObjects();

	// get game container
	GameInterfaceGameContainer *getGameContainer();
	// get editor container
	GameInterfaceEditorContainer *getEditorContainer();

private:
	// interface objects of the game
	std::vector< GameInterfaceObject* > *mInterfaceObjects;

	// game mode related items

	// pointer to the main scene
	GameScene *mGameScene;
	// game item container
	GameInterfaceGameContainer *mGameContainer;

	// editor mode related items

	// pointer to the main scene
	EditorScene *mEditorScene;
	// editor item container
	GameInterfaceEditorContainer *mEditorContainer;

};

#endif